@echo off
echo Start OSFP Debug GUI ...

set webview_path=%cd%
echo %webview_path%

cd ..

rem set root=%cd%
rem set python_path=%root%\Python36\Python36

set PYPATH36=%cd%\Python36\Python36
set PYPATH38=%cd%\Python38\Python38
set PYPATH310=%cd%\Python310\Python310

if exist "%PYPATH36%" (
    echo use python36 env ...
    set python_path=%cd%\Python36\Python36
)

if exist "%PYPATH38%" (
    echo use python38 env ...
    set python_path=%cd%\Python38\Python38
) 

if exist "%PYPATH310%" (
    echo use python310 env ...
    set python_path=%cd%\Python310\Python310
) 

rem current disk
rem %~d0

rem cd %cd%\OSFP-Debug-GUI
cd %webview_path%

rem set PYTHON to environment ariable 
set path=%python_path%;%path%
echo %path%


start "Boku Service" "%python_path%\python.exe" -u "%webview_path%"\app.py
